#!/bin/sh
#
# Script to download SoapUI jars and install them into the local maven repository
#
rm -rf ~/.gradle/caches/modules-2/files-2.1/gnu.cajo
rm -rf ~/.gradle/caches/modules-2/files-2.1/jtidy

# POM is broken in SoapUI repository
curl http://www.soapui.org/repository/maven2/gnu/cajo/cajo/1.142/cajo-1.142.jar > /tmp/cajo-1.142.jar
mvn install:install-file -Dfile=/tmp/cajo-1.142.jar -DgroupId=gnu.cajo -DartifactId=cajo -Dversion=1.142 -Dpackaging=jar

# POM is broken in SoapUI repository
curl http://www.soapui.org/repository/maven2/jtidy/jtidy/r872/jtidy-r872-jdk15.jar > /tmp/jtidy-r872-jdk15.jar
mvn install:install-file -Dfile=/tmp/jtidy-r872-jdk15.jar -DgroupId=jtidy -DartifactId=jtidy -Dversion=r872 -Dpackaging=jar

# Jar is missing from Maven central which stops gradle from looking in the SoapUI repository
curl http://www.soapui.org/repository/maven2/javax/jms/jms/1.1/jms-1.1.jar > /tmp/jms-1.1.jar
mvn install:install-file -Dfile=/tmp/jms-1.1.jar -DgroupId=javax.jms -DartifactId=jms -Dversion=1.1 -Dpackaging=jar
